home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Rockford Magazine
/
Rockford_Magazine_022_19xx_-_de_Disk_2_of_4_Side_B.d64
/
1-3 bowling-rof
(
.txt
)
next >
Wrap
Commodore BASIC
|
2023-02-26
|
3KB
|
98 lines
10 l(1)=1193:l(2)=1273:l(3)=1353:c$(1)=""
11 c$(2)=c$(1)+"":c$(3)=c$(2)+"":c$=c$(1)
12 bo=53280:sc=53281:co=54272:sc(1)=15:sc(2)=0:sc(3)=7:bo(1)=13:bo(2)=2
15 bo(3)=9
17 fort=cotoco+24:poket,0:next:pokeco+24,15:pokeco+5,17:pokeco+6,241:pokeco,30
18 pokeco+1,10
110 pokebo,6:pokesc,7:print"[147]"c$"[145][145][145][145][145]bowling!"
112 print"how many players (1-3)
113 [161]a$:a[178][197](a$):[139]a[179]1[176]a[177]3[167]113
115 x$[178]"names":[139]a[178]1[167]x$[178]"name"
118 [153]"loadtype in your ";x$
120 [129]x[178]1[164]a
121 [153]"player"x":";
122 [133]a$(x)
123 a$(x)[178][200](a$(x),6):[130]
128 [153]"load1 2 3 4 5 6 7 8 9 10 wait ":[153]"";
129 [129]x[178]1[164]10:[153]"1wait2";:[130]:[153]"3wait"
132 [153][163]8)" str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$":[153][163]9)"str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$"
133 [145][171](a[178]1)[137]138
134 [153][163]8)" str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$":[145][171](a[178]2)[137]138
136 [153][163]8)" str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$str$
138 printleft$(c$,12)+" "+a$(1)":"
146 ifa>1thenprinttab(14)+"[145]"+a$(2)":"
150 ifa>2thenprinttab(27)"[145]"+a$(3)":"
154 printleft$(c$,12)"[198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198][198]"
156 print"[197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197][197]"
160 forq=1to10
166 forz9=1toa:pokesc,sc(z9):pokebo,bo(z9)
167 forx=1to10:readv:pokev,81:pokev+co,6:next:restore
169 j=0:g=0
170 gosub430:gosub550:p=l(z9):gosub1000:l(z9)=p
172 gosub1200
174 on-(l(z9)/2=int(l(z9)/2))goto169
175 if(peek(l(z9)-1)=47andq=10)=0then195
178 printleft$(c$,12)+""+a$(z9)+", throw one more!"
180 forx=1to3000:next
182 printleft$(c$,12)+""+" "
183 rem print" "
184 forx=1to10:readv:pokev,81:pokev+co,6:next:restore
190 j=0:gosub430:gosub550:t(z9)=t(z9)+j:printc$(z9);t(z9)
192 k=j+48:ifj+peek(l(z9)-1)-224=10thenk=47
193 ifk=58thenk=152
194 pokel(z9),k:pokel(z9)+co,4:goto225
195 u=0:if(peek(l(z9)-2)=152andq=10)=0then225
198 printleft$(c$,12)+""+a$(z9)+", throw two more!"
202 forx=1to3000:next
203 printleft$(c$,12)+""+" "
206 l(z9)=l(z9)-1
207 forx=1to10:readv:pokev,81:pokev+co,6:next:restore
209 j=0:gosub430:gosub550:t(z9)=t(z9)+j:printc$(z9);t(z9)
210 k=j+176:ifk=186thenk=152
211 pokel(z9),k:pokel(z9)+co,4:l(z9)=l(z9)+1
213 ifpeek(l(z9)-1)=152thenforx=1to10:readv:pokev,81:pokev+co,6:next:restore
214 u=u+1:onugoto209,225
225 nextz9:nextq
230 goto882
430 n=1827:i=40
440 poken,32:n=n+i:ifn<1624orn>1868theni=-i
460 poken+co,-(peek(sc)=240):poken,81:geta$:on-(a$="")goto440:return
550 n=n+1:geta$
554 ifpeek(n)<>81then595
558 q2=n:gosub610
560 pokeco+4,17:poken-1,32:poken+co,-(peek(sc)=240):poken,81:pokeco+4,16
562 forw=1to3
566 ifpeek(n-39*w)=81thenq2=n-39*w:gosub610
569 ifpeek(n+41*w)=81thenq2=n+41*w:gosub610
572 next
595 pokeco+4,17:h=h+1:poken-1,32:poken+co,-(peek(sc)=240):poken,81:pokeco+4,16
597 ifh=36then612
600 goto550
610 j=j+1:pokeco+4,33:pokeq2,32:fort=1to50:next:pokeco+4,32:return
612 h=0:poken,32:poken-1,32:return
882 printc$;"[156]final scores"
883 print""a$(1);t(1):ifa>1thenprint""a$(2);t(2)
884 ifa=3thenprint"";a$(3);t(3)
887 print"again (y/n)?"
894 geta$:ifa$=""then 894
895 ifa$="y"thenrun
896 sys2048
1000 g=j:ifp/2<>int(p/2)theng=g+176
1002 ifg=186theng=152
1004 ifp/2=int(p/2)theng=g+48
1006 ifg+peek(p-1)-224=10theng=47
1012 pokep,g:pokep+co,4:ifg=152thenp=p+1:g=0
1100 p=p+1:return
1200 rem ** scoring *
1201 t(z9)=t(z9)+j
1205 t(z9)=t(z9)-j*(peek(l(z9)-2)=47)
1210 t(z9)=t(z9)-10*(peek(l(z9)-3)=47andpeek(l(z9)-2)=152)
1220 ifl(z9)=1272orl(z9)=1352orl(z9)=1432then1290
1225 t(z9)=t(z9)-j*(peek(l(z9)-4)=152)
1227 t(z9)=t(z9)-j*(peek(l(z9)-3)=152)
1228 t(z9)=t(z9)-j*((peek(l(z9)-5)=152andpeek(l(z9)-3)=152))
1230 t(z9)=t(z9)-j*(peek(l(z9)-6)=152andpeek(l(z9)-4)=152andpeek(l(z9)-2)=152)
1290 printc$(z9);t(z9)
1300 return
2200 data 1661,1700,1739,1741,1778,1780,1819,1821,1860,1901